import {Injectable} from '@angular/core';
import {HttpClient} from '@angular/common/http';
import {Observable} from 'rxjs';

@Injectable({
  providedIn: 'root'
})
export class OrderService {

  constructor(private http: HttpClient) {
  }

  search(queryParams: any): Observable<any> {

    queryParams.sort = 'createTime,DESC';

    return this.http.get(`/wx/orders`, {params: queryParams});
  }
}
